import xlwt

workbook = xlwt.Workbook(encoding='utf-8')
Worksheet = workbook.add_sheet('sheet1')
for i in range(0, 9):
    for j in range(0, i+1):
        Worksheet.write(i, j, "%d * %d = %d" % ((i+1), (j+1), (i+1)*(j+1)))

workbook.save('xlwt99.xls')
